package com.crm.customers.dao.impl;

import java.util.List;

import org.springframework.stereotype.Repository;

import com.crm.base.dao.BaseDao;
import com.crm.customers.dao.CustomerFilesDao;
import com.crm.customers.model.CustomerFiles;

@Repository("customerFilesDao")
public class CustomerFilesDaoImpl extends BaseDao implements CustomerFilesDao {

	
	private static final String MAPPER_NAMESAPCE = "CustomerFilesMapper.";
	
	@Override
	public CustomerFiles insertCustomerFiles(CustomerFiles cf) {
		insert(MAPPER_NAMESAPCE+"insertCustomerFiles", cf);
		return cf;
	}

	@Override
	public List<CustomerFiles> getcustomerfilelistbyid(Long cusid) {
		return selectList(MAPPER_NAMESAPCE+"getcustomerfilelistbyid", cusid);
	}

	@Override
	public CustomerFiles updateCustomerFiles(CustomerFiles cf) {
		update(MAPPER_NAMESAPCE+"updateCustomerFiles", cf);
		return cf;
	}

	@Override
	public int delectCustomerFile(Long id) {
		return update(MAPPER_NAMESAPCE+"deletecustomerfile", id);
	}

	@Override
	public List<CustomerFiles> getCusFilListByParams(CustomerFiles cf) {
		return selectList(MAPPER_NAMESAPCE+"getCusFilListByParams", cf);
	}
	
	

}
